#include "platform.h"
#include "pthread.h"
#include "task.h"

void* raw_task_create(void (*entry)(void *),
                      const char *name,
                      char *stk,
                      size_t stk_size,
                      void *arg,
                      uint8_t priority,
                      uint8_t tick,
                      uint8_t type,
                      err_t *err)
{
    *err = 0;

    return task_create(entry, name, stk, stk_size, arg, priority, tick, type);
}

void raw_task_start(void* task)
{
    tasksched_set_task_ready(task);
}

void raw_task_delete(void* task)
{
    tasksched_delete_task(task);
}

void raw_suspend_task(void *task)
{
    tasksched_set_task_suspend(task);
}

void raw_resume_task(void *task)
{
    tasksched_set_task_ready(task);
}

